import request from '../uniHttp';

// 创建主题
export const createTheme = async (data?: object|any) => {
  return await request('/theme/createTheme', 'post', data);
}

// 获取所有主题数据
export const getThemeList = async (data?: object|any) => {
  return await request('/theme/getThemeList', 'post', data);
}

// 获取指定主题数据
export const getThemeById = async (id?: string|number) => {
  return await request('/theme/getThemeById', 'get', id);
}

// 更新主题数据
export const updateTheme = async (data?: object|any) => {
  return await request('/theme/updateTheme', 'post', data);
}

// 删除主题数据
export const deleteTheme = async (id?: string|number) => {
  return await request('/theme/deleteTheme', 'delete', id);
}

// 主题绑定到用户
export const bindUser = async (data?: object|any) => {
  return await request('/theme/bindUser', 'post', data);
}
